package com.aidex.system.domain;

import com.aidex.common.core.domain.BaseEntity;
import com.aidex.common.utils.log.annotation.FieldRemark;
import com.aidex.common.utils.log.annotation.LogField;
import com.aidex.common.xss.Xss;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;

@Data
@EqualsAndHashCode(callSuper = true)
@Api(tags = "通知公告")
public class SysNotice extends BaseEntity {

    @ApiModelProperty("公告标题")
    @NotBlank(message = "公告标题不能为空")
    @Size(max = 50, message = "公告标题不能超过50个字符")
    @LogField
    @FieldRemark(field = "noticeTitle" , name = "公告标题")
    @Xss(message = "公告标题不能包含脚本字符")
    private String noticeTitle;

    @ApiModelProperty("公告类型")
    @FieldRemark(field = "noticeType" , name = "公告类型")
    private String noticeType;

    @ApiModelProperty("公告内容")
    private String noticeContent;

    @ApiModelProperty("公告内容")
    private String noticeContentHtml;

    @ApiModelProperty("公告状态")
    @FieldRemark(field = "status" , name = "公告状态")
    private String status;
}
